' Copyright ⌐ 1994 by Computer Technologies, Inc. All rights reserved.
' This file provide the APIs, constants, and functions to
' detect file drops on the registered form.
' Using this code requires the use of the MSGBLAST.VBX, or some other
' callback control. (MicroHelp: MHCB200.VBX, Desaware: SBCHOOK.VBX) If
' you use some other callback control, you will need to make some minor
' adjustments to the code, because the parameter names in the events, and
' how you identify the messages you want to watch are different.
Type POINTSTRUCT ' API Point structure
PT_X As Integer
PT_Y As Integer
End Type
Type MSGSTRUCT ' API Message structure
hWnd As Integer
message As Integer
wParam As Integer
lParam As Long
time As Long
pt As POINTSTRUCT
End Type
Global Const WM_SYSCOMMAND = &H112
Global Const WM_DROPFILES = &H233
Declare Sub APIDragAcceptFiles Lib "Shell" Alias "DragAcceptFiles" (ByVal hWnd As Integer, ByVal fAccept As Integer)
Declare Function APIDragQueryFile Lib "Shell" Alias "DragQueryFile" (ByVal hDrop As Integer, ByVal iFile As Integer, ByVal lpszFile As String, ByVal cb As Integer) As Integer
Declare Sub APIDragFinish Lib "Shell" Alias "DragFinish" (ByVal hDrop As Integer)
Declare Function APIPeekMessage Lib "User" Alias "PeekMessage" (lpMsg As MSGSTRUCT, ByVal hWnd As Integer, ByVal wMsgFilterMin As Integer, ByVal wMsgFilterMax As Integer, ByVal wRemoveMsg As Integer) As Integer
Declare Function APIGetPrivateProfileString Lib "Kernel" Alias "GetPrivateProfileString" (ByVal lpAppName As String, ByVal lpKeyName As Any, ByVal lpDefault As String, ByVal lpReturnedString As String, ByVal nSize As Integer, ByVal lpFileName As String) As Integer
Global Const MF_BYCOMMAND = &H0
Global Const MF_APPEND = &H100
Global Const MF_SEPARATOR = &H800
Global Const MF_ENABLED = &H0
Global Const MF_STRING = &H0
Global Const MB_ICONINFORMATION = 64
Global Const IDM_ABOUT = 108
Declare Function APIGetSystemMenu Lib "User" Alias "GetSystemMenu" (ByVal hWnd As Integer, ByVal bRevert As Integer) As Integer
Declare Function APIDeleteMenu Lib "User" Alias "DeleteMenu" (ByVal hMenu As Integer, ByVal nPosition As Integer, ByVal wFlags As Integer) As Integer
Declare Function APIAppendMenu Lib "User" Alias "AppendMenu" (ByVal hMenu As Integer, ByVal wFlags As Integer, ByVal wIDNewItem As Integer, ByVal lpNewItem As Any) As Integer
Sub APP_About ()
' Copyright ⌐ 1994 by Computer Technologies, Inc. All rights reserved.
Dim tTempStr As String
Dim tCRLF As String
tCRLF = Chr$(13) & Chr$(10)
tTempStr = "Copyright ⌐ 1994 by Computer Technologies, Inc." & tCRLF & "All rights reserved."
tTempStr = tTempStr & tCRLF & tCRLF & "Version 1.0 - Released October 11, 1994."
tTempStr = tTempStr & tCRLF & tCRLF & "This demo program and all associated code is the property of Computer Technologies, Inc. It is provided as a service for the personal use of the members of the MS-BASIC forum on CompuServe, and other interested Visual Basic developers."